<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="content-type" content="text/html; charset=utf-8" />
    <title>添加坐标</title>
    <link href="${base}/resource/admin/css/common.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="${base}/resource/admin/js/jquery.js"></script>
    <script type="text/javascript" src="${base}/resource/admin/js/jquery.validate.js"></script>
    <script type="text/javascript" src="${base}/resource/admin/editor/kindeditor.js"></script>
    <script type="text/javascript" src="${base}/resource/admin/js/common.js"></script>
    <script type="text/javascript" src="${base}/resource/admin/js/input.js"></script>
    <script type="text/javascript" src="${base}/resource/admin/layer/layer.js"></script>
    <script type="text/javascript" src="${base}/resource/admin/layer/layer-mext.js"></script>
    <script type="text/javascript">

        $().ready(function() {
            var $inputForm = $("#inputForm");
            [@flash_message /]
            var $browserButton = $("#browserButton");
            $browserButton.browser();

            $("select[name='universityId']").change(function(){
                var opt=$(this).find("option:selected").text();
                $("input[name='universityName']").val(opt);
            });

        });
    </script>
</head>
<body>
<div class="path">
    <a href="${base}/admin/common/index.do">首页</a> &raquo;添加坐标
</div>
<form id="inputForm" action="save.do" method="post" class="required-form" onsubmit="return validateForm(this)">
    <table class="input tabContent">
        <tr>
            <th>
                <span class="requiredField">*</span>院校:
            </th>
            <td>
                <select name="universityId" class="text required">
                    <option value="0" disabled="disabled">空</option>
                    [#list universityList as university]
                    <option value="${university.id}">${university.name}</option>
                     [/#list]
                </select>
                <input type="hidden" name="universityName" value="${universityList[0].name}"/>
            </td>
        </tr>
        <tr>
            <th>
                <span class="requiredField">*</span>名称
            </th>
            <td>
                <input type="text" name="name" class="text required" maxlength="100" />
            </td>
        </tr>
        <tr>
            <th>
                <span class="requiredField">*</span>描述
            </th>
            <td>
                <span class="fieldSet">
                    <input type="text" name="description" class="text"/>
                </span>
            </td>
        </tr>
        <tr>
            <th>
                <span class="requiredField">*</span>获取坐标
            </th>
            <td>
                <span class="fieldSet">
                    <input type="text" name="lng" class="text required"/>
                    <input type="text" name="lat" class="text required"/>
                    <input type="button"  class="layer-map" value="获取坐标">
                </span>
            </td>
        </tr>
        <tr>
            <th>
                &nbsp;
            </th>
            <td>
                <input type="submit" class="button" value="提交" />
                <input type="button" class="button" value="返回" onclick="location.href='list.do'" />
            </td>
        </tr>
    </table>
</form>
</body>
</html>